<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/jsp/common/include.jsp"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" " http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>主页 | 短信平台</title>
<jsp:include page="/WEB-INF/jsp/common/commonlist.jsp"></jsp:include>
</head>
<body onload="bodyLoad()">
<div id="body-wrapper">
  <!-- Wrapper for the radial gradient background -->
  <div id="sidebar">
    <div id="sidebar-wrapper">
      <!-- Sidebar with logo and menu -->
      <h1 id="sidebar-title"><a href="#">短信平台</a></h1> 
      <!-- Logo (221px wide) -->

      <!-- Sidebar Profile links -->
        <!--  页面左上角的部分 -->
     <%@include file="/WEB-INF/jsp/common/leftTop.jsp" %>
     <!-- 页面左侧菜单部分 -->
     <%@include file="/WEB-INF/jsp/common/menu.jsp" %>
    </div>
  </div>
  <!-- End #sidebar -->
  <div id="main-content">
    <!-- Main Content Section with everything -->
    
    <!-- Page Head -->
   <%@ include file="/WEB-INF/jsp/common/top.jsp" %>
    <!-- End .shortcut-buttons-set -->
    <div class="clear"></div>
    <!-- End .clear -->
    <div class="content-box">
      <!-- Start Content Box -->
      <div class="content-box-header">
        <h3>短信分组</h3>
        <ul class="content-box-tabs">
        </ul>
        <div class="clear"></div>
      </div>
      <!-- End .content-box-header -->
      <div class="content-box-content">
        <div class="tab-content default-tab" id="tab1">
        <form action="showGroupList.do" method="post" id="form1">
           <table>
              <tr style="background-color: rgb(229, 229, 229);">
                <td style="width: 40px;"><label style="padding-bottom: 0px;">标识：</label></td>
                <td style="width: 160px;"><input type="text" id="groupId" name="groupId" value="${groupId}"/></td>
                <td><input type="submit" value="查询"></td></tr> 
          </table>
          <table>
            <thead>
              <tr>
                <th>
                  <input class="check-all" type="checkbox" />
                </th>
                <th>ID</th>
                <th>群组名称</th>
                <th>群组介绍</th>
                <th>建组时间</th>
                <th>基础操作</th>
              </tr>
            </thead>
            <tfoot> 
              <tr>
                <td colspan="8">
                  <div class="bulk-actions align-left">
                    <a class="button" href="newGroup.do">新建分组</a>&nbsp;<a class="button" href="showGroupList.do">显示全部</a></div>
                    <div class="pagination" style="font-size: 12px;"> 
                  		<a href="#"   onclick= "submitForm(1)">&laquo; 首页</a>
	                	<a href="#"   onclick="submitForm(${result.previousPage })">&laquo; 上一页</a> 
	               		${result.currPage}/${result.pageCount }
	                    <a href="#"  onclick="submitForm(${result.nextPage})"   title="下一页">下一页 &raquo;</a>
	                    <a href="#"  onclick="submitForm(${result.pageCount})">尾页 &raquo;</a> 
	              	</div>
                  <!-- End .pagination -->
                  <div class="clear"></div>
                </td>
              </tr>
            </tfoot>
            <tbody>
            <c:forEach items="${result.result}" var="list">
              <tr>
                <td>
                  <input type="checkbox" />
                </td>
                <td>${list.groupId}</td>
                <td><a href="#" title="title">${list.groupName}</a></td>
                <td>${list.groupContent}</td>
                <td>${fn:substring(list.createTime,0,4)}-${fn:substring(list.createTime, 4, 6)}-${fn:substring(list.createTime, 6, 8)}</td> 
                <td>
                  <!-- Icons -->
                  <a href="editGroup.do?groupId=${list.groupId}" title="编辑"><img src="images/icons/pencil.png" alt="编辑" /></a> 
                  <a href="delGroup.do?groupId=${list.groupId}" title="删除"><img src="images/icons/cross.png" alt="删除" /></a>
              </tr>
            </c:forEach>
            </tbody>
          </table>
         </form>
        </div>
        <!-- End #tab1 -->
      </div>
      <!-- End .content-box-content -->
    </div>
    <!-- End .content-box -->
    <div class="clear"></div>
    <%@ include file="/WEB-INF/jsp/common/copyright.jsp" %>
  </div>
  <!-- End #main-content -->
</div>
</body>
<script type="text/javascript">
	function bodyLoad(){
		activeMenuItem("messageManageItem","messageGroup");
	}
	//提交查询
	function submitForm(pageNo){
		$('#pageNo').attr("value",pageNo);
		$('#form1').submit();
	}
</script>
</html>